package 进阶.转换流.字符编码和字符集;

import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStreamReader;

public class demo02_InputStreamReader {
    public static void main(String[] args) throws IOException {
        InputStreamReader inputStreamReader = new InputStreamReader(new FileInputStream("d:/a.txt"),"gbk");
        int read = inputStreamReader.read();

        System.out.println((char)read);

        inputStreamReader.close();
    }
}
